﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.InteropServices.WindowsRuntime;
using System.Text;
using System.Threading.Tasks;

namespace Lesson14___练习题
{
    //使用构造函数来完成
    class Worker
    {
        private string type;
        private string content;


        public Worker(string type, string content)  
        {
            this .type = type;  

            this .content = content;    
       
        }
        public void Work()
        {
            Console.WriteLine("{0}{1}",type,content );
        }

    }

    class Plan : Worker 
    {
        public Plan():base("策划","设计游戏")
        {

        }
    }
    class Programmer:Worker
    {
        public Programmer():base("编程","策划游戏")
        {

        }
    }
    class Art:Worker
    { 
    public Art():base("美术","画话")
        {

        }
    }

    internal class Program
    {
        static void Main(string[] args)
        {
            Plan p1= new Plan(); 
            p1.Work();


            Art p2= new Art();  
            p2.Work();  

            Programmer p3 = new Programmer();   

            p3.Work();
            
        }
    }
}
